PreviousNextTracker indexSee it online !

(202/212) 518 - Ability to change readonly status of the buffer (not file!)

When I call "Macros / Files / Toggle ReadOnly", it changes not only readonly status of the buffer but also the permissions of the file.

I want another "ReadOnly", which would make the buffer read-only WITHOUT changing the file attributes.

This is useful when I view a mission-critical file, in order not to damage it incidentally.

Submitted porton - 2016-06-14 11:12:40.377000 Assigned
Priority 5 Labels
Status open Group none
Resolution None

Comments

2017-10-28 22:42:59.333000
ngc

Is this macro sufficient?

textArea.selectAll();
Registers.copy(textArea,'$');
jEdit.newFile(view);
EditBus.send(new PositionChanging(editPane));
Registers.paste(textArea,'$',false);

It will copy the whole file content to a new file.

2017-11-02 22:34:02.829000
tsourick

I believe this feature should be in the core.

2017-11-02 23:49:25.606000
ngc

Hmmm…

I just tested with jEdit 05.04.99.00 on Mac OS X 10.12.6 (x86_64)

I opened a read-only file and had no issues editing it. No need to change a read-only mode.

But when I tried to save, I was asked whether or not I want to reset the read-only mode of the file.

So I think it can be closed as fixed.

2017-11-03 23:12:12.080000
tsourick

This is not what the creator asked for.
The request is about "editing lock" of a buffer, not a file, as title states.